
<div id = "main-content-area">
	<div id = "main-content-wrap">
		<div id = "recipient-area">
			<div id = "ad_wrap" style="display:none;position:absolute;">
				<div id = "top-receptients">
					<h2 style = "float:left; color:#fff; font-size:14px; margin-top:10px; margin-left:10px" >Add Recipient</h2>
				</div>
				<div id = "con-recipients">
					<form id = "edit_receptients_frm" name = "edit_receptients_frm" method="post">
					<?php echo form_hidden('recipient', $this->uri->segment(3)); ?>
						<input id = "hidden1" type = "hidden" value = "<?php echo base_url();?>"/>
						<div class = "error-r"></div>
						<div class = "loader"><img src = "<?php echo base_url();?>assets/images/ajax-loader.gif" alt = "loader" /></div>
						<div id="rec_edit_fields">
						</div>
						<p style = "margin-right:20px;" class="fright">
							<input type="image" value="" alt="" id="recep-edit" src="<?php echo base_url(); ?>assets/images/submit.png">
							<input type="image" value="" alt="" id="recep-edit-cancel" src="<?php echo base_url(); ?>assets/images/cancel.png">
						</p>
					</form>
				</div>
			</div>
			<div id = "recipient-content">
				<div id = "recipient-search-area">
					<form name="frm_rec_search" id="frm_rec_search" method="post">
						<select id = "search-list" name="search-list">
						  <option value="" selected="selected">Search by Name</option>
						  <option value="1">First Name</option>
						  <option value="2">Last Name</option>
						  <option value="3">Middle Name</option>
						</select>
						<input type = "text" name = "r-search" value = "Type Here..." id = "r-search" />
						<input type="image" value="" alt="" id="recipient-searchsubmit" src="<?php echo base_url(); ?>assets/images/f-search-btn.png">
					</form>
				</div>
				<div class = "loader"><img src = "<?php echo base_url();?>assets/images/ajax-loader.gif" alt = "loader" /></div>
				<div id="div_results">
					<div class="pagination">
						<?php echo $pagination; ?>
					</div>
					<div class="clear"></div>
					<div class="notice"></div>
					<input type="hidden" id="path" name="path" value="<?php echo base_url();?>"/>
					<?php foreach ($recipients as $row): ?>
						<div  id = "recipient-context_<?php echo urlencode($this->encryption_lib->encode($row->recipientid)); ?>" class="recipient-context">
							<label><?php echo $row->fname ; ?>&nbsp;<?php echo $row->mname ; ?>&nbsp;<?php echo $row->lname ; ?></label>
							<p><?php echo empty($row->city)? '':$row->city.',';?>&nbsp;<?php echo $row->state;?>&nbsp;<?php echo $row->zip;?></p>
							<p><?php echo $row->phone;?></p>
							<div id = "recipient-control">
								<a href = "javascript:void(0);" onclick="edit_recipient('<?php echo urlencode($this->encryption_lib->encode($row->recipientid)); ?>')"><img src = "<?php echo base_url(); ?>assets/images/edit-btn.png" alt = "Edit" title = "Edit" /></a> &nbsp;&nbsp;&nbsp;
								<a href = "javascript:void(0)" onclick="deleteRecipient('<?php echo urlencode($this->encryption_lib->encode($row->recipientid)); ?>')"><img src = "<?php echo base_url(); ?>assets/images/trash-can.png" alt = "Delete" title = "Delete" /></a>&nbsp;&nbsp;
								|&nbsp;&nbsp;&nbsp;
								<?php
								if($row->is_executor){
									echo '<img src="'.base_url().'assets/images/check.png" alt="An Executor" title="An Executor" />';
								} else {
									echo '<img src="'.base_url().'assets/images/wrong.png" alt="Not an Executor" title="Not an Executor" />';
								}
								?>
							</div>
						</div>
					<?php endforeach; ?>
				</div>
			</div>
		</div>
	</div>
</div>